< previous page page_44 next page >

Page 44
0044-01.jpg
Figure 3.1.
Dynasets contain key sets that point to the actual data.
Note.gif
The actual data request engine used by Visual Basic is called the Microsoft Jet data engine. In pure SQL systems, all requests for data result in a set of data records. Data requests to the Microsoft Jet engine result in a set of keys that point to the data records. By returning keys instead of data records, Microsoft Jet engine is able to limit network traffic and speed database performance.

The set of keys is stored in RAM andif the set is too large to store in RAM alonein a temporary file on a local disk drive. As you scroll through the dataset, Visual Basic retrieves actual records as needed from the physical table used to create the Dynaset. If you have a single text box on the form, Visual Basic retrieves the data from the table one record at a time. If you have a grid of data or a loop that collects several records from the table in succession, a small set of the records in the dataset is retrieved by Visual Basic. Visual Basic also caches records at the workstation to reduce requests to the physical data table, which speeds performance.
If the Dynaset is very large, you might end up with a key set so large that it requires more RAM and temporary disk space than the local machine can handle. In that case, you receive an error message from Visual Basic. For this reason, it is important that you use care in creating your criteria for populating the dataset. The smaller the dataset, the smaller the key set.

 
< previous page page_44 next page >

If you like this book, buy it!